﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:tns="http://dev.virtualearth.net/webservices/v1/common" elementFormDefault="qualified" targetNamespace="http://dev.virtualearth.net/webservices/v1/common" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:import schemaLocation="http://dev.virtualearth.net/webservices/v1/metadata/routeservice/routeservice1.xsd" namespace="http://schemas.microsoft.com/2003/10/Serialization/" />
  <xs:complexType name="RequestBase">
    <xs:sequence>
      <xs:element minOccurs="0" name="Credentials" nillable="true" type="tns:Credentials" />
      <xs:element minOccurs="0" name="Culture" nillable="true" type="xs:string" />
      <xs:element minOccurs="0" name="ExecutionOptions" nillable="true" type="tns:ExecutionOptions" />
      <xs:element minOccurs="0" name="UserProfile" nillable="true" type="tns:UserProfile" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="RequestBase" nillable="true" type="tns:RequestBase" />
  <xs:complexType name="Credentials">
    <xs:sequence>
      <xs:element minOccurs="0" name="ApplicationId" nillable="true" type="xs:string" />
      <xs:element minOccurs="0" name="Token" nillable="true" type="xs:string" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="Credentials" nillable="true" type="tns:Credentials" />
  <xs:complexType name="ExecutionOptions">
    <xs:sequence>
      <xs:element minOccurs="0" name="SuppressFaults" type="xs:boolean" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="ExecutionOptions" nillable="true" type="tns:ExecutionOptions" />
  <xs:complexType name="UserProfile">
    <xs:sequence>
      <xs:element minOccurs="0" name="CurrentHeading" nillable="true" type="tns:Heading" />
      <xs:element minOccurs="0" name="CurrentLocation" nillable="true" type="tns:UserLocation" />
      <xs:element minOccurs="0" name="DeviceType" type="tns:DeviceType" />
      <xs:element minOccurs="0" name="DistanceUnit" type="tns:DistanceUnit" />
      <xs:element minOccurs="0" name="IPAddress" nillable="true" type="xs:string" />
      <xs:element minOccurs="0" name="MapView" nillable="true" type="tns:ShapeBase" />
      <xs:element minOccurs="0" name="ScreenSize" nillable="true" type="tns:SizeOfint" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="UserProfile" nillable="true" type="tns:UserProfile" />
  <xs:complexType name="Heading">
    <xs:sequence>
      <xs:element minOccurs="0" name="Orientation" type="xs:double" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="Heading" nillable="true" type="tns:Heading" />
  <xs:complexType name="UserLocation">
    <xs:complexContent mixed="false">
      <xs:extension base="tns:Location">
        <xs:sequence>
          <xs:element minOccurs="0" name="Confidence" type="tns:Confidence" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name="UserLocation" nillable="true" type="tns:UserLocation" />
  <xs:complexType name="Location">
    <xs:sequence>
      <xs:element minOccurs="0" name="Altitude" type="xs:double" />
      <xs:element minOccurs="0" name="Latitude" type="xs:double" />
      <xs:element minOccurs="0" name="Longitude" type="xs:double" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="Location" nillable="true" type="tns:Location" />
  <xs:complexType name="GeocodeLocation">
    <xs:complexContent mixed="false">
      <xs:extension base="tns:Location">
        <xs:sequence>
          <xs:element minOccurs="0" name="CalculationMethod" nillable="true" type="xs:string" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name="GeocodeLocation" nillable="true" type="tns:GeocodeLocation" />
  <xs:simpleType name="Confidence">
    <xs:restriction base="xs:string">
      <xs:enumeration value="High" />
      <xs:enumeration value="Medium" />
      <xs:enumeration value="Low" />
    </xs:restriction>
  </xs:simpleType>
  <xs:element name="Confidence" nillable="true" type="tns:Confidence" />
  <xs:simpleType name="DeviceType">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Desktop" />
      <xs:enumeration value="Mobile" />
    </xs:restriction>
  </xs:simpleType>
  <xs:element name="DeviceType" nillable="true" type="tns:DeviceType" />
  <xs:simpleType name="DistanceUnit">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Kilometer" />
      <xs:enumeration value="Mile" />
    </xs:restriction>
  </xs:simpleType>
  <xs:element name="DistanceUnit" nillable="true" type="tns:DistanceUnit" />
  <xs:complexType name="ShapeBase">
    <xs:sequence />
  </xs:complexType>
  <xs:element name="ShapeBase" nillable="true" type="tns:ShapeBase" />
  <xs:complexType name="Rectangle">
    <xs:complexContent mixed="false">
      <xs:extension base="tns:ShapeBase">
        <xs:sequence>
          <xs:element minOccurs="0" name="Northeast" nillable="true" type="tns:Location" />
          <xs:element minOccurs="0" name="Southwest" nillable="true" type="tns:Location" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name="Rectangle" nillable="true" type="tns:Rectangle" />
  <xs:complexType name="Circle">
    <xs:complexContent mixed="false">
      <xs:extension base="tns:ShapeBase">
        <xs:sequence>
          <xs:element minOccurs="0" name="Center" nillable="true" type="tns:Location" />
          <xs:element minOccurs="0" name="DistanceUnit" type="tns:DistanceUnit" />
          <xs:element minOccurs="0" name="Radius" type="xs:double" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name="Circle" nillable="true" type="tns:Circle" />
  <xs:complexType name="Polygon">
    <xs:complexContent mixed="false">
      <xs:extension base="tns:ShapeBase">
        <xs:sequence>
          <xs:element minOccurs="0" name="Vertices" nillable="true" type="tns:ArrayOfLocation" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  <xs:element name="Polygon" nillable="true" type="tns:Polygon" />
  <xs:complexType name="ArrayOfLocation">
    <xs:sequence>
      <xs:element minOccurs="0" maxOccurs="unbounded" name="Location" nillable="true" type="tns:Location" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="ArrayOfLocation" nillable="true" type="tns:ArrayOfLocation" />
  <xs:complexType name="SizeOfint">
    <xs:annotation>
      <xs:appinfo>
        <GenericType Name="SizeOf{0}{#}" Namespace="http://dev.virtualearth.net/webservices/v1/common" xmlns="http://schemas.microsoft.com/2003/10/Serialization/">
          <GenericParameter Name="int" Namespace="http://www.w3.org/2001/XMLSchema" />
        </GenericType>
      </xs:appinfo>
    </xs:annotation>
    <xs:sequence>
      <xs:element minOccurs="0" name="Height" type="xs:int" />
      <xs:element minOccurs="0" name="Width" type="xs:int" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="SizeOfint" nillable="true" type="tns:SizeOfint" />
  <xs:complexType name="ResponseBase">
    <xs:sequence>
      <xs:element minOccurs="0" name="BrandLogoUri" nillable="true" type="xs:anyURI" />
      <xs:element minOccurs="0" name="ResponseSummary" nillable="true" type="tns:ResponseSummary" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="ResponseBase" nillable="true" type="tns:ResponseBase" />
  <xs:complexType name="ResponseSummary">
    <xs:sequence>
      <xs:element minOccurs="0" name="AuthenticationResultCode" type="tns:AuthenticationResultCode" />
      <xs:element minOccurs="0" name="Copyright" nillable="true" type="xs:string" />
      <xs:element minOccurs="0" name="FaultReason" nillable="true" type="xs:string" />
      <xs:element minOccurs="0" name="StatusCode" type="tns:ResponseStatusCode" />
      <xs:element minOccurs="0" name="TraceId" nillable="true" type="xs:string" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="ResponseSummary" nillable="true" type="tns:ResponseSummary" />
  <xs:simpleType name="AuthenticationResultCode">
    <xs:restriction base="xs:string">
      <xs:enumeration value="None" />
      <xs:enumeration value="NoCredentials" />
      <xs:enumeration value="ValidCredentials" />
      <xs:enumeration value="InvalidCredentials" />
      <xs:enumeration value="CredentialsExpired" />
      <xs:enumeration value="NotAuthorized">
        <xs:annotation>
          <xs:appinfo>
            <EnumerationValue xmlns="http://schemas.microsoft.com/2003/10/Serialization/">7</EnumerationValue>
          </xs:appinfo>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>
  <xs:element name="AuthenticationResultCode" nillable="true" type="tns:AuthenticationResultCode" />
  <xs:simpleType name="ResponseStatusCode">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Success" />
      <xs:enumeration value="BadRequest" />
      <xs:enumeration value="ServerError" />
    </xs:restriction>
  </xs:simpleType>
  <xs:element name="ResponseStatusCode" nillable="true" type="tns:ResponseStatusCode" />
</xs:schema>